/*
 * XML Type:  XPageViewForm
 * Namespace: http://www.seedwill.com/xul/form/
 * Java type: com.seedwill.xul.form.XPageViewForm
 *
 * Automatically generated - do not modify.
 */
package com.seedwill.xul.form.impl;
/**
 * An XML XPageViewForm(@http://www.seedwill.com/xul/form/).
 *
 * This is a complex type.
 */
public class XPageViewFormImpl extends com.seedwill.xul.form.impl.XFormImpl implements com.seedwill.xul.form.XPageViewForm
{
    private static final long serialVersionUID = 1L;
    
    public XPageViewFormImpl(org.apache.xmlbeans.SchemaType sType)
    {
        super(sType);
    }
    
    private static final javax.xml.namespace.QName PAGEVIEW$0 = 
        new javax.xml.namespace.QName("", "pageView");
    private static final javax.xml.namespace.QName ENABLEPAGNATION$2 = 
        new javax.xml.namespace.QName("", "enablePagnation");
    
    
    /**
     * Gets the "pageView" element
     */
    public com.seedwill.xul.widget.XPageView getPageView()
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.seedwill.xul.widget.XPageView target = null;
            target = (com.seedwill.xul.widget.XPageView)get_store().find_element_user(PAGEVIEW$0, 0);
            if (target == null)
            {
                return null;
            }
            return target;
        }
    }
    
    /**
     * Sets the "pageView" element
     */
    public void setPageView(com.seedwill.xul.widget.XPageView pageView)
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.seedwill.xul.widget.XPageView target = null;
            target = (com.seedwill.xul.widget.XPageView)get_store().find_element_user(PAGEVIEW$0, 0);
            if (target == null)
            {
                target = (com.seedwill.xul.widget.XPageView)get_store().add_element_user(PAGEVIEW$0);
            }
            target.set(pageView);
        }
    }
    
    /**
     * Appends and returns a new empty "pageView" element
     */
    public com.seedwill.xul.widget.XPageView addNewPageView()
    {
        synchronized (monitor())
        {
            check_orphaned();
            com.seedwill.xul.widget.XPageView target = null;
            target = (com.seedwill.xul.widget.XPageView)get_store().add_element_user(PAGEVIEW$0);
            return target;
        }
    }
    
    /**
     * Gets the "enablePagnation" attribute
     */
    public boolean getEnablePagnation()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(ENABLEPAGNATION$2);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_default_attribute_value(ENABLEPAGNATION$2);
            }
            if (target == null)
            {
                return false;
            }
            return target.getBooleanValue();
        }
    }
    
    /**
     * Gets (as xml) the "enablePagnation" attribute
     */
    public org.apache.xmlbeans.XmlBoolean xgetEnablePagnation()
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlBoolean target = null;
            target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(ENABLEPAGNATION$2);
            if (target == null)
            {
                target = (org.apache.xmlbeans.XmlBoolean)get_default_attribute_value(ENABLEPAGNATION$2);
            }
            return target;
        }
    }
    
    /**
     * True if has "enablePagnation" attribute
     */
    public boolean isSetEnablePagnation()
    {
        synchronized (monitor())
        {
            check_orphaned();
            return get_store().find_attribute_user(ENABLEPAGNATION$2) != null;
        }
    }
    
    /**
     * Sets the "enablePagnation" attribute
     */
    public void setEnablePagnation(boolean enablePagnation)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.SimpleValue target = null;
            target = (org.apache.xmlbeans.SimpleValue)get_store().find_attribute_user(ENABLEPAGNATION$2);
            if (target == null)
            {
                target = (org.apache.xmlbeans.SimpleValue)get_store().add_attribute_user(ENABLEPAGNATION$2);
            }
            target.setBooleanValue(enablePagnation);
        }
    }
    
    /**
     * Sets (as xml) the "enablePagnation" attribute
     */
    public void xsetEnablePagnation(org.apache.xmlbeans.XmlBoolean enablePagnation)
    {
        synchronized (monitor())
        {
            check_orphaned();
            org.apache.xmlbeans.XmlBoolean target = null;
            target = (org.apache.xmlbeans.XmlBoolean)get_store().find_attribute_user(ENABLEPAGNATION$2);
            if (target == null)
            {
                target = (org.apache.xmlbeans.XmlBoolean)get_store().add_attribute_user(ENABLEPAGNATION$2);
            }
            target.set(enablePagnation);
        }
    }
    
    /**
     * Unsets the "enablePagnation" attribute
     */
    public void unsetEnablePagnation()
    {
        synchronized (monitor())
        {
            check_orphaned();
            get_store().remove_attribute(ENABLEPAGNATION$2);
        }
    }
}
